<?php
	class Component
	{
		private $id;
		private $name;
		private $description;
		private $price;
		private $category;
		private $stock;
		
		// overloaded constructor, if parameters aren't inserted they default to null
		function __construct($id=null, $name=null, $description=null, $stock=null, $price=null, $category=null)
		{
			$this->id = $id;
			$this->name = $name;
			$this->description = $description;
			$this->stock = $stock;
			$this->price = $price;
			$this->category = $category;
		}
		
		function getId()
		{	
			return $this->id;
		}

		function setId($id)
		{
			$this->id = $id;
		}

		function getName()
		{	
			return $this->name;
		}

		function setName($name)
		{
			$this->name = $name;
		}

		function getDescription()
		{	
			return $this->description;
		}

		function setDescription($description)
		{
			$this->description = $description;
		}

		function getStock()
		{	
			return $this->stock;
		}

		function setStock($stock)
		{
			$this->stock = $stock;
		}

		function getPrice()
		{	
			return $this->price;
		}

		function setPrice($price)
		{
			$this->price = $price;
		}

		function getCategory()
		{	
			return $this->category;
		}

		function setCategory($category)
		{
			$this->category = $category;
		}
	}
?>
